﻿using Ekton_Manage_DomainCore.Aggregate;
using Ekton_Manage_InfrastructureCore.Common;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;

namespace Ekton_Manage_IBusiness
{
    /// <summary>
    /// 系统消息
    /// </summary>
    public interface IApiSelectSysMsg
    {
        /// <summary>
        /// 查询前端用户的所有消息
        /// </summary>
        /// <param name="query"></param>
        /// <returns></returns>
        Task<Tuple<List<user_msg>, int>> GetMsgList(QueryDataParame query);

        /// <summary>
        /// 查询用户的详细消息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>

        Task<Tuple<List<user_msg>, int>> GetUserMsg(QueryDataParame query);
        /// <summary>
        /// 用户点击过之后，将这条消息的状态改为已读
        /// </summary>
        /// <returns></returns>
        Task<Message> PutSysMsgState(int id);

        Task<Message> GetMsgCount(int user_id);

        /// <summary>
        /// 批量修改系统消息状态
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<Message> PutAllSysMsgState(int id);
    }
}
